package com.example.controller;

import com.example.pojo.EmpQueryParam;
import com.example.pojo.OperateLog;
import com.example.pojo.PageResult;
import com.example.pojo.Result;
import com.example.service.OperateLogService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * operatelogController 类的描述信息
 *
 * @author 12427
 * @since 2025/6/9 14:38
 */
@Slf4j
@RestController
@RequestMapping("/log")
public class OperateLogController {
    //    参数注入
    private OperateLogService operateLogService;

    public OperateLogController(OperateLogService operateLogService) {
        this.operateLogService = operateLogService;
    }

    @GetMapping("/page")
    public Result selectLog(EmpQueryParam empQueryParam) {
//        operateLogService.selectLog();
        PageResult<OperateLog> logPageResult = operateLogService.selectLog(empQueryParam);
        return Result.success(logPageResult);
    }

}
